From d3fa64928f574db48799d98fe4093ddd22a0812e Mon Sep 17 00:00:00 2001 From: Ewan Mellor Date: Mon, 25 Dec 2006 14:59:11 +0000 Subject: [PATCH] Added get_record method. By Alastair Tse . Signed-off-by: Ewan Mellor --- tools/python/xen/xend/XendVDI.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/tools/python/xen/xend/XendVDI.py b/tools/python/xen/xend/XendVDI.py index 22a1616360..205aa0a091 100644 --- a/tools/python/xen/xend/XendVDI.py +++ b/tools/python/xen/xend/XendVDI.py @@ -141,6 +141,21 @@ class XendVDI(AutoSaveObject): return True + def get_record(self): + return {'uuid': self.uuid, + 'name_label': self.name_label, + 'name_description': self.name_description, + 'virtual_size': self.virtual_size, + 'physical_utilisation': self.physical_utilisation, + 'sector_size': self.sector_size, + 'parent': None, + 'children': [], + 'sharable': False, + 'readonly': False, + 'SR': self.sr.get_uuid(), + 'VBDs': []} + + class XendQCOWVDI(XendVDI): def __init__(self, uuid, sr_uuid, qcow_path, cfg_path, vsize, psize): -- 2.30.2